import {createRouter, createWebHistory} from 'vue-router'
// @ts-ignore
import NProgress from 'nprogress'
NProgress.configure({showSpinner: false})
import HelloWorld from '../components/HelloWorld.vue'
import Home from '../components/home.vue'

const routers = [
    {
        path: "/we",
        component: HelloWorld
    },
    {
        path: "/",
        component: Home
    },

]

const router = createRouter({
    history: createWebHistory(),
    routes: routers
})


// router.beforeEach((to, from, next) => {
//     NProgress.start()
//     next();
// })
//
// router.afterEach((to, from, next) => {
//     NProgress.done()
// })

export default router;